import Pen.Color.*;
import Pen.Model.*;
import Pen.Type.*;

public class Main {
    public static void main(String[] args) {
        // 创建不同颜色的笔
        IPenColor blueColor = new Blue();
        IPenColor greenColor = new Green();
        IPenColor redColor = new Red();

        // 创建不同型号的笔
        IPenModel boldModel = new Bold();
        IPenModel lightModel = new Light();
        IPenModel mediumModel = new Medium();

        // 创建不同类型的笔并测试
        PenTypeAbstract ballpointPen = new BallpointPen(blueColor, boldModel);
        PenTypeAbstract brush = new Brush(greenColor, lightModel);
        PenTypeAbstract pencil = new Pencil(redColor, mediumModel);

        // 测试各种类型的笔
        testPen(ballpointPen);
        testPen(brush);
        testPen(pencil);
    }

    // 测试笔的方法
    public static void testPen(PenTypeAbstract pen) {
        System.out.println("测试用:");
        pen.Pen();
        System.out.println();
    }
}
